/**
 * 维信科技
 * 实现迷你运算器，实现对于俩个数的+，-，*，/运算
 * @author Mr.Wang
 * @time 20180930
 */
package day02;

import java.util.Scanner;

public class HomeWork2 {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		System.out.println("-----迷你运算器------");
		System.out.println("请输入第一个数:");
		double a=in.nextDouble(); 
		System.out.println("请输入第二个数:");
		double b=in.nextDouble();
		System.out.println("请输入你要的运算方式(+,-,*,/):");
		String num = in.next();
		switch(num) {
		case "+":
			System.out.println(a+"+"+b+"="+(a+b));
			break;
		case "-":
			System.out.println(a+"-"+b+"="+(a-b));
			break;
		case "*":
			System.out.println(a+"*"+b+"="+(a*b));
			break;
		case "/":
			System.out.println(a+"/"+b+"="+(a/b));
			break;
		}

	}

}
